<template>
  <div class="layout">
    <Layout>
      <div class="layout-main">
          <articleList :tableBody='tableBody'></articleList>
          <div class="sider">
            <h3>网站分类</h3>
            <div class="sider-list">
              <div class="list" v-for='(item,index) in type' :key='index'>
                {{item}}
              </div>
            </div>
            <router-link to="/article/list" class="go-new">
              <img src="~#/go-new-world.png" alt="">
            </router-link>
          </div>
      </div>
      <Footer class="layout-footer-center">2018-Infinity &copy; Fignting</Footer>
    </Layout>
  </div>
</template>
<script>
import Bll from './bll'
import articleList from '@/components/articleList/articleList'
export default {
  name: 'home',
  data () {
    return {
      tableBody: [],
      type: [
        'html',
        'css',
        'javaScript',
        'vue',
        'react'
      ]
    }
  },
  created () {
    this.bll = new Bll(this)
    this.bll.getArticleList()
  },
  components: {
    articleList
  },
  methods: {
    enter (id) {
      this.$router.push(`/article/${id}`)
    }
  }
}
</script>

<style scoped lang='less'>
  @import url('./index');
</style>
